package com.ruoyi.houseinfo.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.houseinfo.mapper.HouseContarctHouseinfoMapper;
import com.ruoyi.houseinfo.domain.HouseContarctHouseinfo;
import com.ruoyi.houseinfo.service.IHouseContarctHouseinfoService;

/**
 * 合同和房间的关系Service业务层处理
 * 
 * @author hct
 * @date 2022-02-16
 */
@Service
public class HouseContarctHouseinfoServiceImpl implements IHouseContarctHouseinfoService 
{
    @Autowired
    private HouseContarctHouseinfoMapper houseContarctHouseinfoMapper;

    /**
     * 查询合同和房间的关系
     * 
     * @param id 合同和房间的关系主键
     * @return 合同和房间的关系
     */
    @Override
    public HouseContarctHouseinfo selectHouseContarctHouseinfoById(Long id)
    {
        return houseContarctHouseinfoMapper.selectHouseContarctHouseinfoById(id);
    }

    /**
     * 查询合同和房间的关系列表
     * 
     * @param houseContarctHouseinfo 合同和房间的关系
     * @return 合同和房间的关系
     */
    @Override
    public List<HouseContarctHouseinfo> selectHouseContarctHouseinfoList(HouseContarctHouseinfo houseContarctHouseinfo)
    {
        return houseContarctHouseinfoMapper.selectHouseContarctHouseinfoList(houseContarctHouseinfo);
    }

    /**
     * 新增合同和房间的关系
     * 
     * @param houseContarctHouseinfo 合同和房间的关系
     * @return 结果
     */
    @Override
    public int insertHouseContarctHouseinfo(HouseContarctHouseinfo houseContarctHouseinfo)
    {
        return houseContarctHouseinfoMapper.insertHouseContarctHouseinfo(houseContarctHouseinfo);
    }

    /**
     * 修改合同和房间的关系
     * 
     * @param houseContarctHouseinfo 合同和房间的关系
     * @return 结果
     */
    @Override
    public int updateHouseContarctHouseinfo(HouseContarctHouseinfo houseContarctHouseinfo)
    {
        return houseContarctHouseinfoMapper.updateHouseContarctHouseinfo(houseContarctHouseinfo);
    }

    /**
     * 批量删除合同和房间的关系
     * 
     * @param ids 需要删除的合同和房间的关系主键
     * @return 结果
     */
    @Override
    public int deleteHouseContarctHouseinfoByIds(Long[] ids)
    {
        return houseContarctHouseinfoMapper.deleteHouseContarctHouseinfoByIds(ids);
    }

    /**
     * 删除合同和房间的关系信息
     * 
     * @param id 合同和房间的关系主键
     * @return 结果
     */
    @Override
    public int deleteHouseContarctHouseinfoById(Long id)
    {
        return houseContarctHouseinfoMapper.deleteHouseContarctHouseinfoById(id);
    }
}
